package com.libing.util;

import java.sql.Timestamp;
import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * @Description:
 * @Author: WangY
 * @Date: Created in 2018-08-25 1:03
 * @Modified By：
 */

public class TimeUtil {

    public static Timestamp getNewTime() {
        Date date = new Date();//获得系统时间.

        String nowTime = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(date);//将时间格式转换成符合Timestamp要求的格式.
        Timestamp goodsC_date = Timestamp.valueOf(nowTime);//把时间转换
        return goodsC_date;
    }
}
